<!doctype html>
<html class="default no-js">
<head>
	<meta charset="utf-8">
	<meta http-equiv="X-UA-Compatible" content="IE=edge">
	<title>&quot;core/sketch_support&quot; | @magenta/sketch</title>
	<meta name="description" content="">
	<meta name="viewport" content="width=device-width, initial-scale=1">
	<link rel="stylesheet" href="../assets/css/main.css">
</head>
<body>
<header>
	<div class="tsd-page-toolbar">
		<div class="container">
			<div class="table-wrap">
				<div class="table-cell" id="tsd-search" data-index="../assets/js/search.js" data-base="..">
					<div class="field">
						<label for="tsd-search-field" class="tsd-widget search no-caption">Search</label>
						<input id="tsd-search-field" type="text" />
					</div>
					<ul class="results">
						<li class="state loading">Preparing search index...</li>
						<li class="state failure">The search index is not available</li>
					</ul>
					<a href="../index.html" class="title">@magenta/sketch</a>
				</div>
				<div class="table-cell" id="tsd-widgets">
					<div id="tsd-filter">
						<a href="#" class="tsd-widget options no-caption" data-toggle="options">Options</a>
						<div class="tsd-filter-group">
							<div class="tsd-select" id="tsd-filter-visibility">
								<span class="tsd-select-label">All</span>
								<ul class="tsd-select-list">
									<li data-value="public">Public</li>
									<li data-value="protected">Public/Protected</li>
									<li data-value="private" class="selected">All</li>
								</ul>
							</div>
							<input type="checkbox" id="tsd-filter-inherited" checked />
							<label class="tsd-widget" for="tsd-filter-inherited">Inherited</label>
							<input type="checkbox" id="tsd-filter-only-exported" />
							<label class="tsd-widget" for="tsd-filter-only-exported">Only exported</label>
						</div>
					</div>
					<a href="#" class="tsd-widget menu no-caption" data-toggle="menu">Menu</a>
				</div>
			</div>
		</div>
	</div>
	<div class="tsd-page-title">
		<div class="container">
			<ul class="tsd-breadcrumb">
				<li>
					<a href="../globals.html">Globals</a>
				</li>
				<li>
					<a href="_core_sketch_support_.html">&quot;core/sketch_support&quot;</a>
				</li>
			</ul>
			<h1>External module &quot;core/sketch_support&quot;</h1>
		</div>
	</div>
</header>
<div class="container container-main">
	<div class="row">
		<div class="col-8 col-content">
			<section class="tsd-panel tsd-comment">
				<div class="tsd-comment tsd-typography">
					<div class="lead">
						<p>Support modules used by SketchRNN</p>
					</div>
					<dl class="tsd-comment-tags">
						<dt>license</dt>
						<dd><p>Copyright 2018 Google Inc. All Rights Reserved.</p>
							<p>Licensed under the Apache License, Version 2.0 (the &quot;License&quot;);
								you may not use this file except in compliance with the License.
							You may obtain a copy of the License at</p>
							<p>   <a href="http://www.apache.org/licenses/LICENSE-2.0">http://www.apache.org/licenses/LICENSE-2.0</a></p>
							<p>Unless required by applicable law or agreed to in writing, software
								distributed under the License is distributed on an &quot;AS IS&quot; BASIS,
								WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
								See the License for the specific language governing permissions and
							limitations under the License.</p>
						</dd>
					</dl>
				</div>
			</section>
			<section class="tsd-panel-group tsd-index-group">
				<h2>Index</h2>
				<section class="tsd-panel tsd-index-panel">
					<div class="tsd-index-content">
						<section class="tsd-index-section tsd-is-not-exported">
							<h3>Variables</h3>
							<ul class="tsd-index-list">
								<li class="tsd-kind-variable tsd-parent-kind-external-module tsd-is-not-exported"><a href="_core_sketch_support_.html#returnv" class="tsd-kind-icon">returnV</a></li>
								<li class="tsd-kind-variable tsd-parent-kind-external-module tsd-is-not-exported"><a href="_core_sketch_support_.html#vval" class="tsd-kind-icon">v<wbr>Val</a></li>
							</ul>
						</section>
						<section class="tsd-index-section ">
							<h3>Functions</h3>
							<ul class="tsd-index-list">
								<li class="tsd-kind-function tsd-parent-kind-external-module"><a href="_core_sketch_support_.html#birandn" class="tsd-kind-icon">birandn</a></li>
								<li class="tsd-kind-function tsd-parent-kind-external-module"><a href="_core_sketch_support_.html#gaussrandom" class="tsd-kind-icon">gauss<wbr>Random</a></li>
								<li class="tsd-kind-function tsd-parent-kind-external-module"><a href="_core_sketch_support_.html#linetostroke" class="tsd-kind-icon">line<wbr>ToStroke</a></li>
								<li class="tsd-kind-function tsd-parent-kind-external-module"><a href="_core_sketch_support_.html#linestostrokes" class="tsd-kind-icon">lines<wbr>ToStrokes</a></li>
								<li class="tsd-kind-function tsd-parent-kind-external-module"><a href="_core_sketch_support_.html#randf" class="tsd-kind-icon">randf</a></li>
								<li class="tsd-kind-function tsd-parent-kind-external-module"><a href="_core_sketch_support_.html#randi" class="tsd-kind-icon">randi</a></li>
								<li class="tsd-kind-function tsd-parent-kind-external-module"><a href="_core_sketch_support_.html#randn" class="tsd-kind-icon">randn</a></li>
								<li class="tsd-kind-function tsd-parent-kind-external-module"><a href="_core_sketch_support_.html#samplesoftmax" class="tsd-kind-icon">sample<wbr>Softmax</a></li>
								<li class="tsd-kind-function tsd-parent-kind-external-module"><a href="_core_sketch_support_.html#simplifyline" class="tsd-kind-icon">simplify<wbr>Line</a></li>
								<li class="tsd-kind-function tsd-parent-kind-external-module"><a href="_core_sketch_support_.html#simplifylines" class="tsd-kind-icon">simplify<wbr>Lines</a></li>
								<li class="tsd-kind-function tsd-parent-kind-external-module"><a href="_core_sketch_support_.html#stringtoarray" class="tsd-kind-icon">string<wbr>ToArray</a></li>
								<li class="tsd-kind-function tsd-parent-kind-external-module"><a href="_core_sketch_support_.html#stringtouint8array" class="tsd-kind-icon">string<wbr>ToUint8array</a></li>
							</ul>
						</section>
					</div>
				</section>
			</section>
			<section class="tsd-panel-group tsd-member-group tsd-is-not-exported">
				<h2>Variables</h2>
				<section class="tsd-panel tsd-member tsd-kind-variable tsd-parent-kind-external-module tsd-is-not-exported">
					<a name="returnv" class="tsd-anchor"></a>
					<h3><span class="tsd-flag ts-flagLet">Let</span> returnV</h3>
					<div class="tsd-signature tsd-kind-icon">returnV<span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">boolean</span><span class="tsd-signature-symbol"> =&nbsp;false</span></div>
					<aside class="tsd-sources">
						<ul>
							<li>Defined in <a href="https://github.com/tensorflow/magenta-js/tree/master/sketch/src/core/sketch_support.ts#L50">core/sketch_support.ts:50</a></li>
						</ul>
					</aside>
				</section>
				<section class="tsd-panel tsd-member tsd-kind-variable tsd-parent-kind-external-module tsd-is-not-exported">
					<a name="vval" class="tsd-anchor"></a>
					<h3><span class="tsd-flag ts-flagLet">Let</span> v<wbr>Val</h3>
					<div class="tsd-signature tsd-kind-icon">v<wbr>Val<span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">number</span><span class="tsd-signature-symbol"> =&nbsp;0</span></div>
					<aside class="tsd-sources">
						<ul>
							<li>Defined in <a href="https://github.com/tensorflow/magenta-js/tree/master/sketch/src/core/sketch_support.ts#L51">core/sketch_support.ts:51</a></li>
						</ul>
					</aside>
				</section>
			</section>
			<section class="tsd-panel-group tsd-member-group ">
				<h2>Functions</h2>
				<section class="tsd-panel tsd-member tsd-kind-function tsd-parent-kind-external-module">
					<a name="birandn" class="tsd-anchor"></a>
					<h3>birandn</h3>
					<ul class="tsd-signatures tsd-kind-function tsd-parent-kind-external-module">
						<li class="tsd-signature tsd-kind-icon">birandn<span class="tsd-signature-symbol">(</span>mu1<span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">number</span>, mu2<span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">number</span>, std1<span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">number</span>, std2<span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">number</span>, rho<span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">[]</span></li>
					</ul>
					<ul class="tsd-descriptions">
						<li class="tsd-description">
							<aside class="tsd-sources">
								<ul>
									<li>Defined in <a href="https://github.com/tensorflow/magenta-js/tree/master/sketch/src/core/sketch_support.ts#L78">core/sketch_support.ts:78</a></li>
								</ul>
							</aside>
							<h4 class="tsd-parameters-title">Parameters</h4>
							<ul class="tsd-parameters">
								<li>
									<h5>mu1: <span class="tsd-signature-type">number</span></h5>
								</li>
								<li>
									<h5>mu2: <span class="tsd-signature-type">number</span></h5>
								</li>
								<li>
									<h5>std1: <span class="tsd-signature-type">number</span></h5>
								</li>
								<li>
									<h5>std2: <span class="tsd-signature-type">number</span></h5>
								</li>
								<li>
									<h5>rho: <span class="tsd-signature-type">number</span></h5>
								</li>
							</ul>
							<h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">[]</span></h4>
						</li>
					</ul>
				</section>
				<section class="tsd-panel tsd-member tsd-kind-function tsd-parent-kind-external-module">
					<a name="gaussrandom" class="tsd-anchor"></a>
					<h3>gauss<wbr>Random</h3>
					<ul class="tsd-signatures tsd-kind-function tsd-parent-kind-external-module">
						<li class="tsd-signature tsd-kind-icon">gauss<wbr>Random<span class="tsd-signature-symbol">(</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">number</span></li>
					</ul>
					<ul class="tsd-descriptions">
						<li class="tsd-description">
							<aside class="tsd-sources">
								<ul>
									<li>Defined in <a href="https://github.com/tensorflow/magenta-js/tree/master/sketch/src/core/sketch_support.ts#L52">core/sketch_support.ts:52</a></li>
								</ul>
							</aside>
							<h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">number</span></h4>
						</li>
					</ul>
				</section>
				<section class="tsd-panel tsd-member tsd-kind-function tsd-parent-kind-external-module">
					<a name="linetostroke" class="tsd-anchor"></a>
					<h3>line<wbr>ToStroke</h3>
					<ul class="tsd-signatures tsd-kind-function tsd-parent-kind-external-module">
						<li class="tsd-signature tsd-kind-icon">line<wbr>ToStroke<span class="tsd-signature-symbol">(</span>line<span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">[]</span>, lastPoint<span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">[]</span></li>
					</ul>
					<ul class="tsd-descriptions">
						<li class="tsd-description">
							<aside class="tsd-sources">
								<ul>
									<li>Defined in <a href="https://github.com/tensorflow/magenta-js/tree/master/sketch/src/core/sketch_support.ts#L287">core/sketch_support.ts:287</a></li>
								</ul>
							</aside>
							<div class="tsd-comment tsd-typography">
								<div class="lead">
									<p>Convert to stroke-5 format to polyline</p>
								</div>
							</div>
							<h4 class="tsd-parameters-title">Parameters</h4>
							<ul class="tsd-parameters">
								<li>
									<h5>line: <span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">[]</span></h5>
								</li>
								<li>
									<h5>lastPoint: <span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">[]</span></h5>
								</li>
							</ul>
							<h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">[]</span></h4>
						</li>
					</ul>
				</section>
				<section class="tsd-panel tsd-member tsd-kind-function tsd-parent-kind-external-module">
					<a name="linestostrokes" class="tsd-anchor"></a>
					<h3>lines<wbr>ToStrokes</h3>
					<ul class="tsd-signatures tsd-kind-function tsd-parent-kind-external-module">
						<li class="tsd-signature tsd-kind-icon">lines<wbr>ToStrokes<span class="tsd-signature-symbol">(</span>rawData<span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">[]</span></li>
					</ul>
					<ul class="tsd-descriptions">
						<li class="tsd-description">
							<aside class="tsd-sources">
								<ul>
									<li>Defined in <a href="https://github.com/tensorflow/magenta-js/tree/master/sketch/src/core/sketch_support.ts#L249">core/sketch_support.ts:249</a></li>
								</ul>
							</aside>
							<div class="tsd-comment tsd-typography">
								<div class="lead">
									<p>Convert from polylines to stroke-5 format that sketch-rnn uses</p>
								</div>
							</div>
							<h4 class="tsd-parameters-title">Parameters</h4>
							<ul class="tsd-parameters">
								<li>
									<h5>rawData: <span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">[]</span></h5>
								</li>
							</ul>
							<h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">[]</span></h4>
						</li>
					</ul>
				</section>
				<section class="tsd-panel tsd-member tsd-kind-function tsd-parent-kind-external-module">
					<a name="randf" class="tsd-anchor"></a>
					<h3>randf</h3>
					<ul class="tsd-signatures tsd-kind-function tsd-parent-kind-external-module">
						<li class="tsd-signature tsd-kind-icon">randf<span class="tsd-signature-symbol">(</span>a<span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">number</span>, b<span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">number</span></li>
					</ul>
					<ul class="tsd-descriptions">
						<li class="tsd-description">
							<aside class="tsd-sources">
								<ul>
									<li>Defined in <a href="https://github.com/tensorflow/magenta-js/tree/master/sketch/src/core/sketch_support.ts#L68">core/sketch_support.ts:68</a></li>
								</ul>
							</aside>
							<h4 class="tsd-parameters-title">Parameters</h4>
							<ul class="tsd-parameters">
								<li>
									<h5>a: <span class="tsd-signature-type">number</span></h5>
								</li>
								<li>
									<h5>b: <span class="tsd-signature-type">number</span></h5>
								</li>
							</ul>
							<h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">number</span></h4>
						</li>
					</ul>
				</section>
				<section class="tsd-panel tsd-member tsd-kind-function tsd-parent-kind-external-module">
					<a name="randi" class="tsd-anchor"></a>
					<h3>randi</h3>
					<ul class="tsd-signatures tsd-kind-function tsd-parent-kind-external-module">
						<li class="tsd-signature tsd-kind-icon">randi<span class="tsd-signature-symbol">(</span>a<span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">number</span>, b<span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">number</span></li>
					</ul>
					<ul class="tsd-descriptions">
						<li class="tsd-description">
							<aside class="tsd-sources">
								<ul>
									<li>Defined in <a href="https://github.com/tensorflow/magenta-js/tree/master/sketch/src/core/sketch_support.ts#L71">core/sketch_support.ts:71</a></li>
								</ul>
							</aside>
							<h4 class="tsd-parameters-title">Parameters</h4>
							<ul class="tsd-parameters">
								<li>
									<h5>a: <span class="tsd-signature-type">number</span></h5>
								</li>
								<li>
									<h5>b: <span class="tsd-signature-type">number</span></h5>
								</li>
							</ul>
							<h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">number</span></h4>
						</li>
					</ul>
				</section>
				<section class="tsd-panel tsd-member tsd-kind-function tsd-parent-kind-external-module">
					<a name="randn" class="tsd-anchor"></a>
					<h3>randn</h3>
					<ul class="tsd-signatures tsd-kind-function tsd-parent-kind-external-module">
						<li class="tsd-signature tsd-kind-icon">randn<span class="tsd-signature-symbol">(</span>mu<span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">number</span>, std<span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">number</span></li>
					</ul>
					<ul class="tsd-descriptions">
						<li class="tsd-description">
							<aside class="tsd-sources">
								<ul>
									<li>Defined in <a href="https://github.com/tensorflow/magenta-js/tree/master/sketch/src/core/sketch_support.ts#L74">core/sketch_support.ts:74</a></li>
								</ul>
							</aside>
							<h4 class="tsd-parameters-title">Parameters</h4>
							<ul class="tsd-parameters">
								<li>
									<h5>mu: <span class="tsd-signature-type">number</span></h5>
								</li>
								<li>
									<h5>std: <span class="tsd-signature-type">number</span></h5>
								</li>
							</ul>
							<h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">number</span></h4>
						</li>
					</ul>
				</section>
				<section class="tsd-panel tsd-member tsd-kind-function tsd-parent-kind-external-module">
					<a name="samplesoftmax" class="tsd-anchor"></a>
					<h3>sample<wbr>Softmax</h3>
					<ul class="tsd-signatures tsd-kind-function tsd-parent-kind-external-module">
						<li class="tsd-signature tsd-kind-icon">sample<wbr>Softmax<span class="tsd-signature-symbol">(</span>zSample<span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol"> | </span><span class="tsd-signature-type">Float32Array</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">number</span></li>
					</ul>
					<ul class="tsd-descriptions">
						<li class="tsd-description">
							<aside class="tsd-sources">
								<ul>
									<li>Defined in <a href="https://github.com/tensorflow/magenta-js/tree/master/sketch/src/core/sketch_support.ts#L94">core/sketch_support.ts:94</a></li>
								</ul>
							</aside>
							<div class="tsd-comment tsd-typography">
								<div class="lead">
									<p>Sample from a categorial distribution</p>
								</div>
							</div>
							<h4 class="tsd-parameters-title">Parameters</h4>
							<ul class="tsd-parameters">
								<li>
									<h5>zSample: <span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol"> | </span><span class="tsd-signature-type">Float32Array</span></h5>
								</li>
							</ul>
							<h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">number</span></h4>
						</li>
					</ul>
				</section>
				<section class="tsd-panel tsd-member tsd-kind-function tsd-parent-kind-external-module">
					<a name="simplifyline" class="tsd-anchor"></a>
					<h3>simplify<wbr>Line</h3>
					<ul class="tsd-signatures tsd-kind-function tsd-parent-kind-external-module">
						<li class="tsd-signature tsd-kind-icon">simplify<wbr>Line<span class="tsd-signature-symbol">(</span>V<span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">[]</span>, tolerance<span class="tsd-signature-symbol">?: </span><span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">[]</span></li>
					</ul>
					<ul class="tsd-descriptions">
						<li class="tsd-description">
							<aside class="tsd-sources">
								<ul>
									<li>Defined in <a href="https://github.com/tensorflow/magenta-js/tree/master/sketch/src/core/sketch_support.ts#L111">core/sketch_support.ts:111</a></li>
								</ul>
							</aside>
							<h4 class="tsd-parameters-title">Parameters</h4>
							<ul class="tsd-parameters">
								<li>
									<h5>V: <span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">[]</span></h5>
								</li>
								<li>
									<h5><span class="tsd-flag ts-flagDefault value">Default value</span> tolerance: <span class="tsd-signature-type">number</span><span class="tsd-signature-symbol"> =&nbsp;2</span></h5>
								</li>
							</ul>
							<h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">[]</span></h4>
						</li>
					</ul>
				</section>
				<section class="tsd-panel tsd-member tsd-kind-function tsd-parent-kind-external-module">
					<a name="simplifylines" class="tsd-anchor"></a>
					<h3>simplify<wbr>Lines</h3>
					<ul class="tsd-signatures tsd-kind-function tsd-parent-kind-external-module">
						<li class="tsd-signature tsd-kind-icon">simplify<wbr>Lines<span class="tsd-signature-symbol">(</span>lines<span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">[]</span>, tolerance<span class="tsd-signature-symbol">?: </span><span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">[]</span></li>
					</ul>
					<ul class="tsd-descriptions">
						<li class="tsd-description">
							<aside class="tsd-sources">
								<ul>
									<li>Defined in <a href="https://github.com/tensorflow/magenta-js/tree/master/sketch/src/core/sketch_support.ts#L233">core/sketch_support.ts:233</a></li>
								</ul>
							</aside>
							<div class="tsd-comment tsd-typography">
								<div class="lead">
									<p>Clean wrapper method to use RDP function.</p>
								</div>
							</div>
							<h4 class="tsd-parameters-title">Parameters</h4>
							<ul class="tsd-parameters">
								<li>
									<h5>lines: <span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">[]</span></h5>
								</li>
								<li>
									<h5><span class="tsd-flag ts-flagOptional">Optional</span> tolerance: <span class="tsd-signature-type">number</span></h5>
								</li>
							</ul>
							<h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">[]</span></h4>
						</li>
					</ul>
				</section>
				<section class="tsd-panel tsd-member tsd-kind-function tsd-parent-kind-external-module">
					<a name="stringtoarray" class="tsd-anchor"></a>
					<h3>string<wbr>ToArray</h3>
					<ul class="tsd-signatures tsd-kind-function tsd-parent-kind-external-module">
						<li class="tsd-signature tsd-kind-icon">string<wbr>ToArray<span class="tsd-signature-symbol">(</span>b64encoded<span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">Int16Array</span></li>
					</ul>
					<ul class="tsd-descriptions">
						<li class="tsd-description">
							<aside class="tsd-sources">
								<ul>
									<li>Defined in <a href="https://github.com/tensorflow/magenta-js/tree/master/sketch/src/core/sketch_support.ts#L41">core/sketch_support.ts:41</a></li>
								</ul>
							</aside>
							<div class="tsd-comment tsd-typography">
								<div class="lead">
									<p>Converts b64 data into int16 array version.</p>
								</div>
							</div>
							<h4 class="tsd-parameters-title">Parameters</h4>
							<ul class="tsd-parameters">
								<li>
									<h5>b64encoded: <span class="tsd-signature-type">string</span></h5>
									<div class="tsd-comment tsd-typography">
										<p>String of b64 encoded data.</p>
									</div>
								</li>
							</ul>
							<h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Int16Array</span></h4>
							<p>int16 version of data.</p>
						</li>
					</ul>
				</section>
				<section class="tsd-panel tsd-member tsd-kind-function tsd-parent-kind-external-module">
					<a name="stringtouint8array" class="tsd-anchor"></a>
					<h3>string<wbr>ToUint8array</h3>
					<ul class="tsd-signatures tsd-kind-function tsd-parent-kind-external-module">
						<li class="tsd-signature tsd-kind-icon">string<wbr>ToUint8array<span class="tsd-signature-symbol">(</span>b64encoded<span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">Uint8Array</span></li>
					</ul>
					<ul class="tsd-descriptions">
						<li class="tsd-description">
							<aside class="tsd-sources">
								<ul>
									<li>Defined in <a href="https://github.com/tensorflow/magenta-js/tree/master/sketch/src/core/sketch_support.ts#L26">core/sketch_support.ts:26</a></li>
								</ul>
							</aside>
							<div class="tsd-comment tsd-typography">
								<div class="lead">
									<p>Deals with decompressing b64 models to uint8 arrays.</p>
								</div>
							</div>
							<h4 class="tsd-parameters-title">Parameters</h4>
							<ul class="tsd-parameters">
								<li>
									<h5>b64encoded: <span class="tsd-signature-type">string</span></h5>
									<div class="tsd-comment tsd-typography">
										<p>String of b64 encoded data.</p>
									</div>
								</li>
							</ul>
							<h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Uint8Array</span></h4>
							<p>uint8 version of data.</p>
						</li>
					</ul>
				</section>
			</section>
		</div>
		<div class="col-4 col-menu menu-sticky-wrap menu-highlight">
			<nav class="tsd-navigation primary">
				<ul>
					<li class="globals  ">
						<a href="../globals.html"><em>Globals</em></a>
					</li>
					<li class="current tsd-kind-external-module">
						<a href="_core_sketch_support_.html">"core/sketch_<wbr>support"</a>
					</li>
					<li class=" tsd-kind-external-module">
						<a href="_sketch_rnn_model_.html">"sketch_<wbr>rnn/model"</a>
					</li>
				</ul>
			</nav>
			<nav class="tsd-navigation secondary menu-sticky">
				<ul class="before-current">
					<li class=" tsd-kind-variable tsd-parent-kind-external-module tsd-is-not-exported">
						<a href="_core_sketch_support_.html#returnv" class="tsd-kind-icon">returnV</a>
					</li>
					<li class=" tsd-kind-variable tsd-parent-kind-external-module tsd-is-not-exported">
						<a href="_core_sketch_support_.html#vval" class="tsd-kind-icon">v<wbr>Val</a>
					</li>
					<li class=" tsd-kind-function tsd-parent-kind-external-module">
						<a href="_core_sketch_support_.html#birandn" class="tsd-kind-icon">birandn</a>
					</li>
					<li class=" tsd-kind-function tsd-parent-kind-external-module">
						<a href="_core_sketch_support_.html#gaussrandom" class="tsd-kind-icon">gauss<wbr>Random</a>
					</li>
					<li class=" tsd-kind-function tsd-parent-kind-external-module">
						<a href="_core_sketch_support_.html#linetostroke" class="tsd-kind-icon">line<wbr>ToStroke</a>
					</li>
					<li class=" tsd-kind-function tsd-parent-kind-external-module">
						<a href="_core_sketch_support_.html#linestostrokes" class="tsd-kind-icon">lines<wbr>ToStrokes</a>
					</li>
					<li class=" tsd-kind-function tsd-parent-kind-external-module">
						<a href="_core_sketch_support_.html#randf" class="tsd-kind-icon">randf</a>
					</li>
					<li class=" tsd-kind-function tsd-parent-kind-external-module">
						<a href="_core_sketch_support_.html#randi" class="tsd-kind-icon">randi</a>
					</li>
					<li class=" tsd-kind-function tsd-parent-kind-external-module">
						<a href="_core_sketch_support_.html#randn" class="tsd-kind-icon">randn</a>
					</li>
					<li class=" tsd-kind-function tsd-parent-kind-external-module">
						<a href="_core_sketch_support_.html#samplesoftmax" class="tsd-kind-icon">sample<wbr>Softmax</a>
					</li>
					<li class=" tsd-kind-function tsd-parent-kind-external-module">
						<a href="_core_sketch_support_.html#simplifyline" class="tsd-kind-icon">simplify<wbr>Line</a>
					</li>
					<li class=" tsd-kind-function tsd-parent-kind-external-module">
						<a href="_core_sketch_support_.html#simplifylines" class="tsd-kind-icon">simplify<wbr>Lines</a>
					</li>
					<li class=" tsd-kind-function tsd-parent-kind-external-module">
						<a href="_core_sketch_support_.html#stringtoarray" class="tsd-kind-icon">string<wbr>ToArray</a>
					</li>
					<li class=" tsd-kind-function tsd-parent-kind-external-module">
						<a href="_core_sketch_support_.html#stringtouint8array" class="tsd-kind-icon">string<wbr>ToUint8array</a>
					</li>
				</ul>
			</nav>
		</div>
	</div>
</div>
<footer class="with-border-bottom">
	<div class="container">
		<h2>Legend</h2>
		<div class="tsd-legend-group">
			<ul class="tsd-legend">
				<li class="tsd-kind-module"><span class="tsd-kind-icon">Module</span></li>
				<li class="tsd-kind-object-literal"><span class="tsd-kind-icon">Object literal</span></li>
				<li class="tsd-kind-variable"><span class="tsd-kind-icon">Variable</span></li>
				<li class="tsd-kind-function"><span class="tsd-kind-icon">Function</span></li>
				<li class="tsd-kind-function tsd-has-type-parameter"><span class="tsd-kind-icon">Function with type parameter</span></li>
				<li class="tsd-kind-index-signature"><span class="tsd-kind-icon">Index signature</span></li>
				<li class="tsd-kind-type-alias"><span class="tsd-kind-icon">Type alias</span></li>
			</ul>
			<ul class="tsd-legend">
				<li class="tsd-kind-enum"><span class="tsd-kind-icon">Enumeration</span></li>
				<li class="tsd-kind-enum-member"><span class="tsd-kind-icon">Enumeration member</span></li>
				<li class="tsd-kind-property tsd-parent-kind-enum"><span class="tsd-kind-icon">Property</span></li>
				<li class="tsd-kind-method tsd-parent-kind-enum"><span class="tsd-kind-icon">Method</span></li>
			</ul>
			<ul class="tsd-legend">
				<li class="tsd-kind-interface"><span class="tsd-kind-icon">Interface</span></li>
				<li class="tsd-kind-interface tsd-has-type-parameter"><span class="tsd-kind-icon">Interface with type parameter</span></li>
				<li class="tsd-kind-constructor tsd-parent-kind-interface"><span class="tsd-kind-icon">Constructor</span></li>
				<li class="tsd-kind-property tsd-parent-kind-interface"><span class="tsd-kind-icon">Property</span></li>
				<li class="tsd-kind-method tsd-parent-kind-interface"><span class="tsd-kind-icon">Method</span></li>
				<li class="tsd-kind-index-signature tsd-parent-kind-interface"><span class="tsd-kind-icon">Index signature</span></li>
			</ul>
			<ul class="tsd-legend">
				<li class="tsd-kind-class"><span class="tsd-kind-icon">Class</span></li>
				<li class="tsd-kind-class tsd-has-type-parameter"><span class="tsd-kind-icon">Class with type parameter</span></li>
				<li class="tsd-kind-constructor tsd-parent-kind-class"><span class="tsd-kind-icon">Constructor</span></li>
				<li class="tsd-kind-property tsd-parent-kind-class"><span class="tsd-kind-icon">Property</span></li>
				<li class="tsd-kind-method tsd-parent-kind-class"><span class="tsd-kind-icon">Method</span></li>
				<li class="tsd-kind-accessor tsd-parent-kind-class"><span class="tsd-kind-icon">Accessor</span></li>
				<li class="tsd-kind-index-signature tsd-parent-kind-class"><span class="tsd-kind-icon">Index signature</span></li>
			</ul>
			<ul class="tsd-legend">
				<li class="tsd-kind-constructor tsd-parent-kind-class tsd-is-inherited"><span class="tsd-kind-icon">Inherited constructor</span></li>
				<li class="tsd-kind-property tsd-parent-kind-class tsd-is-inherited"><span class="tsd-kind-icon">Inherited property</span></li>
				<li class="tsd-kind-method tsd-parent-kind-class tsd-is-inherited"><span class="tsd-kind-icon">Inherited method</span></li>
				<li class="tsd-kind-accessor tsd-parent-kind-class tsd-is-inherited"><span class="tsd-kind-icon">Inherited accessor</span></li>
			</ul>
			<ul class="tsd-legend">
				<li class="tsd-kind-property tsd-parent-kind-class tsd-is-protected"><span class="tsd-kind-icon">Protected property</span></li>
				<li class="tsd-kind-method tsd-parent-kind-class tsd-is-protected"><span class="tsd-kind-icon">Protected method</span></li>
				<li class="tsd-kind-accessor tsd-parent-kind-class tsd-is-protected"><span class="tsd-kind-icon">Protected accessor</span></li>
			</ul>
			<ul class="tsd-legend">
				<li class="tsd-kind-property tsd-parent-kind-class tsd-is-private"><span class="tsd-kind-icon">Private property</span></li>
				<li class="tsd-kind-method tsd-parent-kind-class tsd-is-private"><span class="tsd-kind-icon">Private method</span></li>
				<li class="tsd-kind-accessor tsd-parent-kind-class tsd-is-private"><span class="tsd-kind-icon">Private accessor</span></li>
			</ul>
			<ul class="tsd-legend">
				<li class="tsd-kind-property tsd-parent-kind-class tsd-is-static"><span class="tsd-kind-icon">Static property</span></li>
				<li class="tsd-kind-call-signature tsd-parent-kind-class tsd-is-static"><span class="tsd-kind-icon">Static method</span></li>
			</ul>
		</div>
	</div>
</footer>
<div class="container tsd-generator">
	<p>Generated using <a href="http://typedoc.org/" target="_blank">TypeDoc</a></p>
</div>
<div class="overlay"></div>
<script src="../assets/js/main.js"></script>
<script>if (location.protocol == 'file:') document.write('<script src="../assets/js/search.js"><' + '/script>');</script>
</body>
</html>